package com.pzb.wechat.domain;

import com.alibaba.fastjson.JSONArray;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.io.Serializable;

/**
 * 收货地址对象 wechat_address
 * 
 * @author Mr_Wu
 * @date 2022-01-21
 */
public class WechatAddress implements Serializable
{
    private static final long serialVersionUID = 1L;

    /** 编号 */
    private Long id;

    /** 商户id */
    private String extAppid;

    /** 用户id */
    private String openid;

    /** 联系人 */
    private String contacts;

    /** 联系电话 */
    private String phone;

    private JSONArray region;

    /** 省 */
    private String province;

    /** 市 */
    private String city;

    /** 区县 */
    private String county;

    /** 详细地址 */
    private String address;

    /** 完整地址，完整地址为省市区+详细地址 */
    private String fullAddress;

    /** 是否为默认地址：0为是，1为否 */
    private Integer isDefault;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setExtAppid(String extAppid) 
    {
        this.extAppid = extAppid;
    }

    public String getExtAppid() 
    {
        return extAppid;
    }
    public void setOpenid(String openid) 
    {
        this.openid = openid;
    }

    public String getOpenid() 
    {
        return openid;
    }
    public void setContacts(String contacts) 
    {
        this.contacts = contacts;
    }

    public String getContacts() 
    {
        return contacts;
    }
    public void setPhone(String phone) 
    {
        this.phone = phone;
    }

    public String getPhone() 
    {
        return phone;
    }
    public void setProvince(String province) 
    {
        this.province = province;
    }

    public String getProvince() 
    {
        return province;
    }
    public void setCity(String city) 
    {
        this.city = city;
    }

    public String getCity() 
    {
        return city;
    }
    public void setCounty(String county) 
    {
        this.county = county;
    }

    public String getCounty() 
    {
        return county;
    }
    public void setAddress(String address) 
    {
        this.address = address;
    }

    public String getAddress() 
    {
        return address;
    }
    public void setFullAddress(String fullAddress) 
    {
        this.fullAddress = fullAddress;
    }

    public String getFullAddress() 
    {
        return fullAddress;
    }

    public Integer getIsDefault() {
        return isDefault;
    }

    public void setIsDefault(Integer isDefault) {
        this.isDefault = isDefault;
    }

    public JSONArray getRegion() {
        return region;
    }

    public void setRegion(JSONArray region) {
        this.region = region;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("extAppid", getExtAppid())
            .append("openid", getOpenid())
            .append("contacts", getContacts())
            .append("phone", getPhone())
            .append("province", getProvince())
            .append("city", getCity())
            .append("county", getCounty())
            .append("address", getAddress())
            .append("fullAddress", getFullAddress())
            .append("default", getIsDefault())
            .toString();
    }
}
